﻿using System.Xml.Serialization;
namespace DemoApp.DataAccess
{
    /// <summary>
    ///     Represents a customer of a company.
    /// </summary>
    public class CustomerDao
    {
        /// <summary>
        ///     Gets/sets the e-mail address for the customer.
        /// </summary>
        public string Email { get; set; }

        /// <summary>
        ///     Gets/sets the customer's first name.  If this customer is a
        ///     company, this value stores the company's name.
        /// </summary>
        public string FirstName { get; set; }

        /// <summary>
        ///     Gets/sets whether the customer is a company or a person.
        ///     The default value is false.
        /// </summary>
        public bool IsCompany { get; set; }

        /// <summary>
        ///     Gets/sets the customer's last name.  If this customer is a
        ///     company, this value is not set.
        /// </summary>
        [XmlAttribute]
        public string LastName { get; set; }

        /// <summary>
        ///     Returns the total amount of money spent by the customer.
        /// </summary>
        public double TotalSales { get; set; }
    }
}